<!DOCTYPE html>
<html lang="en" xmlns: xmlns:th="http://www.thymeleaf.org">

<head>
    <meta charset="utf-8"/>
    <meta content="IE=Edge" http-equiv="X-UA-Compatible"/>
    <title>账户安全 - 亿人宝贷款平台</title>
    <!--<script type="text/javascript" src="http://user/static/rsa/utility.js?v=1.0.2"></script>-->
    <meta content="upgrade-insecure-requests" http-equiv="Content-Security-Policy">
    <!--    <link rel="stylesheet" href="/css/accountsafe.css" />-->
    <link href="http://image.xiaoniu88.com/static/WebXn/dist/css/base-ddb0535420.css" rel="stylesheet"/>
    <link rel="stylesheet" th:href="@{/css/apply.css}"/>
    <script>
        window.global = {
            cdn: "//image.xiaoniu88.com",
            siteroot: "http://www.xiaoniu88.com",
            staticPath: "//image.xiaoniu88.com/static/WebXn/dist",
            contextPath: "/user",
            serverTime: "1591846713575" * 1,
            userId: "6086292",
            isLogin: true
        }
    </script>
    <script src="http://image.xiaoniu88.com/static/WebXn/dist/module/common/common-83987ed24e.js" type="text/javascript"></script>
    <link href="//image.xiaoniu88.com/static/WebXn/dist/user/safety/css/style-ed9716a8f6.css" rel="stylesheet"/>
</head>

<body>
<!--<input type="hidden" id="em" th:value="${session.user.email}"/>-->
<input id="isLogin" type="hidden" value="true"/>
<div th:include="common/admin/common::common_footer_script"/>


<!-- 最外层容器container -->
<div class="row">
    <div th:replace="loan/public::head"></div>
</div>
<div class="container">
    <div th:include="common/admin/common::common_footer_script"/>
    <div class="g-account-main">
        <!-- 面包屑冬导航 -->
        <div class="path">
            您现在的位置：<span><a href="/user/toAO">我的账户</a> > 账户安全</span>

        </div>
        <div class="center user-box">
            <!-- 我的账户菜单 -->

            <!--start 我的账户左边菜单列表-->
            <div th:replace="loan/alone/AccountOverview::inflist"/>

            <script src="http://image.xiaoniu88.com/static/WebXn/dist/module/userNavList/js/init-09a2ab6833.js"></script>
            <script>
                $(function () {
                    var islogin = "${sessionScope.user.userName}";
                    if (islogin == null) {
                        window.location.href = "/user/tologin";
                    }
                });
            </script>

            <!--end 我的账户左边菜单列表-->
            <!-- 右侧内容 -->
            <div class="account-cont">
                <!-- 右侧标题 -->
                <div class="at-til">
                    <span class="name">账户安全</span>
                </div>

                <!-- 具体内容-账户安全 -->
                <div class="at-bd red-envelope">
                    <!-- 顶部 -->
                    <div class="zccount_msg">
                        <div id="dialogCode">
                            <div class="recommend_pop">
                                <div class="rp_step rp_step1">
                                    <ul>
                                        <li class="g-cf">
                                            <div class="g-fl rp_field">我的推荐人：</div>
                                            <div class="rp_value">
                                                <input class="rp_txt" id="setrefferee" placeholder="请填写您的推荐人用户名或手机号" type="text"/><br><span class="rp_error">请输入正确的推荐人账号或手机号!</span>
                                            </div>
                                        </li>
                                        <li class="g-cf">
                                            <div class="g-fl rp_field"></div>
                                            <div class="rp_value">
                                                <input class="rp_btn" id="rp_btn" type="button" value="提交"/>
                                            </div>
                                        </li>
                                    </ul>
                                    <p class="rp_tips">您的推荐人成功提交后,将不可更改。</p>
                                </div>
                                <div class="rp_step rp_step2">
                                    <h3>您已成功把<span class="rec_name">**</span>设置为您的推荐人。</h3>
                                    <p>因推荐人唯一性且不可更改，推荐人不会在"我的资料"中显示。</p>
                                    <input class="rp_btn" type="button" value="确定"/>
                                </div>
                            </div>
                        </div>

                    </div>
                    <!-- 账户安全设置列表 -->
                    <div class="account_list">

                        <div class="column" myid='realName' th:if="${session.showcard} eq no">
                            <div class="column_name not_seted">
                                实名认证
                            </div>
                            <div class="column_msg">
                                <span class="setting">
                                    <a myTarget="smdj_rz" th:href="@{/loan/Personal/preapply}">请设置</a>
                                </span>
                                <span class="column_info">合同有效性、资金提现的有力保障，成功提交后不可更改</span>
                                <span class="info_con"></span>
                                <span class="info_con"></span>
                            </div>
                        </div>
                        <div class="column" myid='realName' th:if="${session.showcard} eq yes">
                            <div class="column_name seted">
                                实名认证
                            </div>
                            <div class="column_msg">
                                <span class="setting"><!--th:if="${session.loanUsers.idcard} ne null"-->
                                    <a myTarget="smdj_rz" th:href="@{/loan/Personal/preapply}">查看</a>
                                </span>
                                <span class="column_info">合同有效性、资金提现的有力保障，成功提交后不可更改</span>
                                <span class="info_con"></span>
                                <span class="info_con"></span>
                            </div>
                        </div>

                        <div class="column" myid='carinfo' th:if="${session.carlist} eq no">
                            <div class="column_name not_seted">
                                车辆信息
                            </div>
                            <div class="column_msg">
                                <span class="setting">
                                    <a myTarget="smdj_rz" th:href="@{/loan/Personal/carinfo}">请设置</a>
                                </span>
                                <span class="column_info">合同有效性、资金提现的有力保障，成功提交后不可更改</span>
                                <span class="info_con"></span>
                                <span class="info_con"></span>
                            </div>
                        </div>
                        <div class="column" myid='carinfo' th:if="${session.carlist} eq yes">

                            <div class="column_name seted">
                                车辆信息
                            </div>
                            <div class="column_msg">
                                <span class="setting"><!--th:if="${session.loanUsers.idcard} ne null"-->
                                    <a myTarget="smdj_rz" th:href="@{/loan/Personal/selcarinfo}">查看</a>
                                </span>
                                <span class="column_info">合同有效性、资金提现的有力保障，成功提交后不可更改</span>
                                <span class="info_con"></span>
                                <span class="info_con"></span>
                            </div>
                        </div>

                        <div class="column" myid='houseinfo' th:if="${session.houselist} eq no">
                            <div class="column_name not_seted">
                                房产信息
                            </div>
                            <div class="column_msg">
                                <span class="setting">
                                    <a myTarget="smdj_rz" th:href="@{/loan/Personal/tohouseadd}">请设置</a>
                                </span>
                                <span class="column_info">合同有效性、资金提现的有力保障，成功提交后不可更改</span>
                                <span class="info_con"></span>
                                <span class="info_con"></span>
                            </div>
                        </div>
                        <div class="column" myid='houseinfo' th:if="${session.houselist} eq yes">

                            <div class="column_name seted">
                                房产
                            </div>
                            <div class="column_msg">
                                <span class="setting"><!--th:if="${session.loanUsers.idcard} ne null"-->
                                    <a myTarget="smdj_rz" th:href="@{/loan/Personal/houseinfo}">查看</a>
                                </span>
                                <span class="column_info">合同有效性、资金提现的有力保障，成功提交后不可更改</span>
                                <span class="info_con"></span>
                                <span class="info_con"></span>
                            </div>
                        </div>

                        <!-- 交易密码 -->
                        <div class="column" myid='tdpwd' th:if="null eq ${session.loanUsers.bankpwd}">
                            <div class="column_name not_seted">
                                交易密码
                            </div>
                            <div class="column_msg">
                                <span class="setting"><a myTarget="step_1" th:href="@{/loan/Personal/toBcardPwd}">请设置</a></span>
                                <span class="cancel_setting"><a class="cancel_action">取消</a></span>
                                <span class="column_info">
                                    原提现密码，保障账户资金安全，提现或改动账户信息的时候需要输入的密码
								</span>
                            </div>
                        </div>
                        <div class="column" myid='tdpwd' th:if="null != ${session.loanUsers.bankpwd}">
                            <div class="column_name seted">
                                交易密码
                            </div>
                            <div class="column_msg">
                                <span class="setting"><a myTarget="step_1" th:href="@{/loan/Personal/toBupdPwd}">修改</a></span>
                                <span class="cancel_setting"><a class="cancel_action">取消</a></span>
                                <span class="column_info">
                                    原提现密码，保障账户资金安全，提现或改动账户信息的时候需要输入的密码
								</span>
                            </div>
                        </div>
                        <!-- 邮箱认证 -->
                        <!-- 紧急联系人 --><!--th:if="null eq ${session.loanUsers.phone1}"-->
                        <div class="column" myid="contact" th:if="null eq ${session.loanUsers.phone1}">
                            <div class="column_name not_seted ">
                                紧急联系人
                            </div>
                            <div class="column_msg">
                                <span class="setting"><a class="showSetting" id="jjlxr_sub" th:href="@{/loan/Personal/torelation}">设置</a></span>
                                <span class="cancel_setting"><a class="cancel_action">取消</a></span>
                                <span class="column_info">当有紧急情况联系不到您的时候，可以联系您的亲人朋友</span>
                                <span class="info_con"></span>
                                <span class="info_con"></span>
                            </div>
                        </div>
                        <div class="column" myid="assess" th:if="null eq ${session.loanUsers.limits}">
                            <div class="column_name seted">申请额度</div>
                            <div class="column_msg">
                                <span class="setting"><a class="btn" th:href="@{/loan/Personal/addassess(id=${session.loanUsers.id})}">申请额度</a></span>
                                <span class="column_info">为了不影响您之后的贷款，请您立即申请</span>
                            </div>
                        </div>
                        <div class="column" myid="assess" th:if="null ne ${session.loanUsers.limits}">
                            <div class="column_name seted">额度申请</div>
                            <div class="column_msg">
                                <span class="column_info">申请完成 用户金额：<strong><span th:text="${session.loanUsers.limits}"></span></strong></span>
                                <span th:if="${session.loanUsers.assessstate} eq 0">申请状态 ：未申请</span>
                                <span th:if="${session.loanUsers.assessstate} eq 1">申请状态 ：申请中</span>
                                <span th:if="${session.loanUsers.assessstate} eq 2">申请状态 ：已完成</span>
                                <span class="setting"><!--th:if="${session.loanUsers.idcard} ne null"-->
                                <a onclick="pinggu()" myTarget="smdj_rz" >申请</a>
                                </span>

                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<script src="http://image.xiaoniu88.com/static/WebXn/dist/user/safety/js/init-4d458ed0f9.js"></script>
<div class="row">
    <!--网站底部-->
    <div th:replace="common/public::footer"></div>
</div>


<!--end 尾部-->

<script type="text/javascript">
    $(window).bind("load", function () {
        $("#safe").css("background", "#658297");
        $("#colorsafe").css("color", "#fff");
    });

    var jishi = 59;
    var jishuTishi;
    var yhMa;

    function getMa(type, id) {
        yhMa = null;
        var email = $("#em").val();
        var val = $(id).firstElementChild;
        if ($("#get_code_text").text() === "获取验证码") {
            $("#jymm_step1_get_code").css("background-color", "ccc");
            $("#get_code_text").html('获取(59)');

            jishuTishi = setInterval("daojishi()", "1000");

            $.post("/user/getMa", {email: email, type: type}, function (data) {
                if (data === "" || data == null) {
                    alert("请检查邮箱格式是否正确");
                    $("#jymm_step1_codeTip").replaceWith("<span class=\"bindcard-tip errTip\" id=\"jymm_step1_codeTip\">发送验证码失败</span>");
                } else {
                    yhMa = data;
                    alert(yhMa);
                    $("#jymi_step1_codetemp").attr("value", yhMa);
                }
            }, "json");
        } else {
            //已经在获取验证码
            $(".bindcard-msg").attr("disaply", "block");
        }
    }

    function daojishi() {
        jishi -= 1;
        if (jishi === 0) {
            jishi = 59;
            clearInterval(jishuTishi);
            $("#get_code_text").html('获取验证码');
            $("#jymm_step1_get_code").css("border", "1px solid #fd7500");
            $("#jymm_step1_get_code").css("background-color", "#fd7500");
            $("#get_code_text").css("background-color", "#fd7500");
        } else {
            $("#jymm_step1_get_code").css("border", "1px solid #ccc");
            $("#jymm_step1_get_code").css("background-color", "#ccc");
            $("#get_code_text").css("background-color", "#ccc");
            $("#get_code_text").html("获取(" + jishi + ")");
        }
    }

    var submitBtn = document.getElementById("jjlxr_sub");
    submitBtn.onclick = function (ev) {

    }

    function pinggu() {
        $.ajax({
            type: "post",
            dataType: "json",
            url: "/erb/loan/Personal/pinggu", //发送请求地址
            data: {

            },
            success: function (data) {
                if (data == 1) {
                    alert("请先完善车辆信息");
                } else if (data == 2) {
                    alert("请先完善房产信息");
                } else if (data == 3) {
                    window.location.href = "addassess";
                }
            }

        })
    }

</script>
</body>
</html>